package com.whq.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.whq.dao.BasicMapper;
import com.whq.entity.Basic;
import com.whq.service.BasicService;

@Service(value = "tcBasicService")
public class BasicServiceImpl implements BasicService {

    @Autowired
    private BasicMapper<Basic>tcBasicMapper;
    
    @Override
    public Integer insertSelective(Basic tcBasic) throws Exception {
           return this.tcBasicMapper.insertSelective(tcBasic);
        }

    @Override
    public Integer insertBatch(List<Basic> tcBasic) throws Exception {
           return this.tcBasicMapper.insertBatch(tcBasic) ;
        }

    @Override
    public Integer deleteByPrimaryKey(Object id) {
            return this.tcBasicMapper.deleteByPrimaryKey(id);
    }

    public Integer deleteBatchByPrimaryKey(List<Object> ids) {
           return this.tcBasicMapper.deleteBatchByPrimaryKey(ids);
    }

    @Override
    public Integer updateByPrimaryKeySelective(Basic tcBasic) {
           return this.tcBasicMapper.updateByPrimaryKeySelective(tcBasic);
    }

    @Override
    public Basic findById(Object id) {
           return (Basic) this.tcBasicMapper.selectByPrimaryKey(id);
    }

    @Override
    public List<Basic> selectByCondition(Basic tcBasic) {
           return (List<Basic>) this.tcBasicMapper.selectByCondition(tcBasic);
    }

    @Override
    public Integer selectCountByCondition(Basic tcBasic) {
           return  this.tcBasicMapper.selectCountByCondition(tcBasic);
    }

}
